package com.xbongbong.pro.dynamic.pojo.dto;

import com.xbongbong.paas.pojo.dto.FormDataUpdateBatchDTO;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import lombok.ToString;

import java.io.Serializable;
import java.util.List;

/**
 *动态批量更新
 *
 *@author weijianxun
 */
@Setter
@Getter
@ToString
@NoArgsConstructor
public class DynamicUpdateBatchDTO implements Serializable {
    private static final long serialVersionUID = -6746410175810812527L;

    private FormDataUpdateBatchDTO formDataUpdateBatchDTO;
    private List<Long> allowUpdateDataIds;

    public DynamicUpdateBatchDTO(FormDataUpdateBatchDTO formDataUpdateBatchDTO, List<Long> allowUpdateDataIds) {
        this.formDataUpdateBatchDTO = formDataUpdateBatchDTO;
        this.allowUpdateDataIds = allowUpdateDataIds;
    }


    public static DynamicUpdateBatchDTO initDynamicUpdateBatchDTO(FormDataUpdateBatchDTO formDataUpdateBatchDTO, List<Long> allowUpdateDataIds) {
        return new DynamicUpdateBatchDTO(formDataUpdateBatchDTO, allowUpdateDataIds);
    }

}
